<!DOCTYPE html>
<html>
{include file="public/head" /}
<body>
          <div class="nav-tabs-custom" style="box-shadow:0 0 0 0; margin:5px;">
        <form id="myform" class="myform form-horizontal"  method="post">
        <input type="hidden" id="collect_id" name="collect_id" value="{$info['collect_id']|default=''}"> 
       <div class="box-body">
           <div class="row">
               <div class="input-group margin15">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-title">所属模型：</span>
                <span class="form-left-title-hide"></span>
                </div>
                <!-- /btn-group -->
                <select name="collect_cid" class="form-control select2" style="width: 100%;">
		{volist name=":config('model')" id="model"}
        {notin name="model['id']" value="7,8,9,10,11,13"}
		<option value="{$model['id']}" {if isset($info['collect_cid']) && $info['collect_cid'] == $model['id']}selected{/if}>{$model.title}</option>
        {/notin}
		{/volist}
        <option value="99" {eq name="info['collect_cid']" value="99"}selected{/eq}>评论</option>
                </select>
              </div>    
     
               <div class="input-group margin15">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-title">资源名称：</span>
                <span class="form-left-title-hide"></span>
                </div>
                <!-- /btn-group -->
             <input type="text" class="form-control" id="collect_name" name="collect_name" value="{$info.collect_name|default=''}" >
              </div>
               <div class="input-group margin15">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-title">资源URL：</span>
                <span class="form-left-title-hide"></span>
                </div>
                <!-- /btn-group -->
             <input type="url" class="form-control" name="collect_url" value="{$info.collect_url|default=''}">
              </div>                  
                 <div class="input-group margin15">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-title">其他参数：</span>
                <span class="form-left-title-hide"></span>
                </div>
                <!-- /btn-group -->
             <input type="text" class="form-control" id="collect_other" name="collect_other" value="{$info.collect_other|default=''}" placeholder="一般使用&开头 如官方只获取某个播放组 &play=yuku 多个参数使用&凭拼接">
              </div>  
                  <div class="input-group margin15">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-title">资源类型：</span>
                <span class="form-left-title-hide"></span>
                </div>
                <!-- /btn-group -->
                <select name="collect_type" class="form-control select2" style="width: 100%;">
                        <option value="2">JSON</option>
                        <option value="1" {if isset($info['collect_type']) && $info['collect_type']==1}selected{/if}>XML</option>
                </select>
              </div>                                                                    
     
                <div class="input-group margin15">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-title">资源描述：</span>
                <span class="form-left-title-hide"></span>
                </div>
                <!-- /btn-group -->
                <textarea  class="form-control"  id="collect_title" name="collect_title"  style=" width:100%; height:50px">{$info['collect_title']|default=''}</textarea>
              </div>
                 <div class="input-group margin15">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-title">资源介绍：</span>
                <span class="form-left-title-hide"></span>
                </div>
                <!-- /btn-group -->
                <textarea  class="form-control"  id="collect_remark" name="collect_remark"  style=" width:100%; height:50px">{$info['collect_remark']|default=''}</textarea>
              </div>               
                <div class="input-group margin15">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-title">资源排序：</span>
                <span class="form-left-title-hide"></span>
                </div>
                <!-- /btn-group -->
               <input type="text" class="form-control w30" name="collect_oid" value="{$info.collect_oid|default=''}" autocomplete="false" placeholder="越小越前面" style="text-align:center;">
              </div>             
               <div class="input-group margin15">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-title">资源状态：</span>
                 <span class="form-left-title-hide"></span>
                </div>
                <!-- /btn-group -->
                   <select name="collect_status" class="form-control select2" style="width:100%;">
                        <option value="0">正常</option>
                        <option value="1" {eq name="info.collect_status" value="1" }selected{/eq}>锁定</option>
                    </select>
              </div>              
               </div>
              <!-- /row --> 

         
        <div class="box-footer {notempty name=":request()->param('dialog')"}hidden{/notempty} layer-footer">
          <div  class="footer-btn">
               <button type="submit" class="btn btn-success btn-embossed">确定</button>
               <button type="reset" class="btn btn-default btn-embossed">重置</button>
               {notempty name=":request()->param('dialog')"}
               <button type="reset" class="btn btn-primary btn-embossed btn-close" onClick="layer.closeAll();"> 关闭</button>
               {/notempty}
            </div>
       </div>
       <!-- /.box-footer -->     
</div>
<!-- /.box-body --> 
</form>
</div>
<!-- /.nav-tabs-custom -->    
{include file="public/footer" /}
<script type="text/javascript">
$(document).ready(function(){
	zanpian.cms.vod();
    $(document).on('click', ".addurl", function() {
			var $old = $("#urldata>.urldata:last").html();
			$urln = $("#urldata>.urldata").length;
			$old = $old.replace("周期" + $urln, "周期" + ($urln + 1));
			$("#urldata>.urldata:last-child").after('<div class="urldata input-group mb10" id="data_' + ($urln + 1) + '">' + $old + '</div>');
			$("#urldata>.urldata:last #collect_date").val($("#collect_date:last option").val());
			$("#urldata>.urldata:last textarea").val('');
					
	})		

});	
</script>
</body>
</html>
